import matplotlib.pyplot as plt
import numpy as np

x = np.linspace(-1000, 1000, 10000)

y = x
plt.plot(x,y, color='red', label='y=x')

y2 = x**2
plt.plot(x,y2, color='green', label='y = x^2')

# y3增长的太快了，看的有问题
y3 = 3 * x * x * x + 5 * x * x + 2 * x + 1
print(3*100*100*100+5*100*100+2*100+1)
plt.plot(x,y3, color='blue', label='y3 = 3 * x^3 + 5 * x^2 + 2*x + 1')
plt.ylim(-1000,1000)

plt.legend()
plt.show()
